summaryrefslogtreecommitdiff
path: root/src/pages/posts/[...page].astro
diff options
context:
space:
mode:
authorDawid Rycerz <dawid@rycerz.xyz>2026-01-13 17:13:43 +0100
committerDawid Rycerz <dawid@rycerz.xyz>2026-01-13 17:20:15 +0100
commit9fe4480c3981c38ae8e24d0495df957039864a5d (patch)
treea5f3e4f8c0732c8cd934c28596c6a4d0ab38a4b4 /src/pages/posts/[...page].astro
parentc0dcecc43e36eeb6b10f662c1be760736cd0dbac (diff)
Remove micro and migrate to use only posts
Diffstat (limited to 'src/pages/posts/[...page].astro')
-rw-r--r--src/pages/posts/[...page].astro6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/pages/posts/[...page].astro b/src/pages/posts/[...page].astro
index acca040..d318525 100644
--- a/src/pages/posts/[...page].astro
+++ b/src/pages/posts/[...page].astro
@@ -12,7 +12,11 @@ export const getStaticPaths = (async ({ paginate }) => {
const MAX_POSTS_PER_PAGE = 10;
const MAX_TAGS = 7;
const allPosts = await getAllPosts();
- const sortedPosts = allPosts.sort(collectionDateSort);
+ // Filter out archived and microblog posts from main posts page
+ const filteredPosts = allPosts.filter(
+ (post) => !post.data.tags.includes("archived") && !post.data.tags.includes("microblog"),
+ );
+ const sortedPosts = filteredPosts.sort(collectionDateSort);
const uniqueTags = getUniqueTags(sortedPosts).slice(0, MAX_TAGS);
return paginate(sortedPosts, {
pageSize: MAX_POSTS_PER_PAGE,